package com.bizihang.validate.code.core;


import java.util.Optional;

/**
 * 验证码存储器
 */
public interface ValidateCodeRepository {
    /**
     * 存储
     *
     * @param client
     * @param validateCode
     */
    void save(Client client, ValidateCode validateCode);

    /**
     * 获取
     *
     * @param client
     * @return
     */
    Optional<ValidateCode> get(Client client);

    /**
     * 删除验证码
     *
     * @param client
     */
    void remove(Client client);
}
